﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Security.Principal;
using System.Web;
using System.Web.Security;

namespace ArticleWeb
{
    public static class UserExtension
    {
        public static bool IsAdministrator(this IPrincipal principal)
        {
            if (principal.Identity.IsAuthenticated)
            {
                if (principal.Identity.Name == "AEAdmin")
                {
                    return true;
                }
            }
            return false;
        }
    }
}